<template>
	<view>
		<empty-data-tip v-show="false"></empty-data-tip>
		<uni-fab :pattern="pattern" horizontal="right" vertical="bottom" popMenu="false" @fabClick="createHouse()" />
		<view class="house-card" @click="goToProject()">
			<view class="house-top">
				<image src="/static/house_info_icons/building.png" class="left-icon"></image>
				<text class="house-name">轻松地产</text>
				<text class="house-status">待审核</text>
			</view>
			<view class="house-buttom">
				<text class="project-name"> 轻松项目</text>
				<text class="house-type">35栋·4单元·1489·两室一厅</text>
				<text class="house-address">深圳市龙华区油松科技大厦</text>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				pattern: {
					buttonColor: "#E62129"
				}
			};
		},
		methods: {
			goTo(URL) {
				uni.navigateTo({
					url: URL
				})
			},
			goToProject() {
				this.goTo('/subpkg/house_info/house_info')
			},
			createHouse() {
				this.goTo('/subpkg/create_house/create_house')
			}
		}
	}
</script>

<style lang="scss">
	.house-card {
		display: flex;
		flex-direction: column;
		border-radius: 20rpx;
		border: 1rpx solid #efefef;
		background: #FFFFFF;
		margin: 20rpx 30rpx 0 30rpx;

		.house-top {
			display: flex;
			flex-direction: row;
			align-items: center;

			.left-icon {
				margin-left: 20rpx;
				width: 34rpx;
				height: 31rpx;
			}

			.house-name {
				margin-left: 15rpx;
				font-size: 30rpx;
				color: #333333;
				font-weight: bold;
			}

			.house-status {
				text-align: center;
				margin-top: 36rpx;
				margin-left: 360rpx;
				width: 120rpx;
				font-size: 24rpx;
				background: linear-gradient(90deg, #E93423 0%, #FB6858 100%);
				border-radius: 22rpx;
				color: #FFFFFF;
			}
		}

		.house-buttom {
			display: flex;
			flex-direction: column;
			margin-top: 29rpx;
			margin-left: 20rpx;
			color: #999999;
			font-size: 24rpx;

			.project-name {
				font-size: 28rpx;
				font-weight: 500;
				color: #333333;
			}

			.house-type {
				margin-top: 16rpx;

			}

			.house-address {
				margin-top: 16rpx;
				margin-bottom: 38rpx;
			}
		}
	}
</style>
